- page_title @protected_ref.name, _("Protected Branches")

.row.gl-mt-3.gl-mb-3
  .gl-col-lg-3
    %h4.gl-mt-0.ref-name
      = @protected_ref.name

  .gl-col-lg-9
    %h5= s_("ProtectedBranch|Matching Branches")
    - if @matching_refs.present?
      .table-responsive
        %table.table.protected-branches-list
          %colgroup
            %col{ width: "30%" }
            %col{ width: "30%" }
          %thead
            %tr
              %th= s_("ProtectedBranch|Branch")
              %th= s_("ProtectedBranch|Last commit")
          %tbody
            - @matching_refs.each do |matching_branch|
              = render partial: "protected_branches/shared/matching_branch", locals: { branch_name: matching_branch.name }
        = render('kaminari/gitlab/without_count', previous_path: @prev_path, next_path: @next_path, event_tracking: nil)
    - else
      = render Pajamas::AlertComponent.new(variant: :warning, dismissible: false) do |c|
        - c.with_body do
          = s_("ProtectedBranch|Couldn't find any matching branches.")
